package com.zkthink.ceres.member.entity;


import cn.afterturn.easypoi.excel.annotation.Excel;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.zkthink.base.entity.Entity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;

import java.time.LocalDateTime;

/**
 * <p>
 * 实体类 会员推荐关系表
 * </p>
 *
 * @author chenke
 * @since 2020-11-27
 */
@Data
@NoArgsConstructor
@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("ceres_member_recommend")
@ApiModel(value = "MemberRecommend", description = "会员推荐关系表")
@AllArgsConstructor
public class MemberRecommend extends Entity<Long> {

    private static final long serialVersionUID = 1L;

    /**
     * 会员ID
     */
    @ApiModelProperty(value = "会员ID")
    @TableField("mid")
    @Excel(name = "会员ID")
    private Long mid;

    /**
     * 直推人ID
     */
    @ApiModelProperty(value = "直推人ID")
    @TableField("first_mid")
    @Excel(name = "会员ID")
    private Long firstMid;

    /**
     * 间推人ID
     */
    @ApiModelProperty(value = "间推人ID")
    @TableField("second_mid")
    @Excel(name = "间推人ID")
    private Long secondMid;

    /**
     * 临时推荐人id
     */
    @ApiModelProperty(value = "临时推荐人id:用于临时存储预销户")
    @TableField("tmp_mid")
    @Excel(name = "临时推荐人id")
    private Long tmpMid;


    @Builder
    public MemberRecommend(Long id, LocalDateTime createTime, LocalDateTime updateTime, Long createUser, Long updateUser,
                           Long mid, Long firstMid, Long secondMid, Long tmpMid) {
        this.id = id;
        this.createTime = createTime;
        this.updateTime = updateTime;
        this.createUser = createUser;
        this.updateUser = updateUser;
        this.mid = mid;
        this.firstMid = firstMid;
        this.secondMid = secondMid;
        this.tmpMid = tmpMid;

    }
}
